package com.lnking.lnkingplace.service;

import com.lnking.lnkingplace.model.dto.notice.NoticeDetailDto;
import com.lnking.lnkingplace.model.dto.read.ReadStatisticsDto;
import com.lnking.lnkingplace.model.entity.Notice;
import com.lnking.lnkingplace.model.request.notice.NoticeAddRequest;
import com.lnking.lnkingplace.model.request.notice.NoticeUpdateRequest;
import com.lnking.starter.mybatis.service.ICustomService;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author zhangqt
 * @since 2022-08-19
 */
public interface INoticeService extends ICustomService<Notice> {

    /**
     * 创建
     * @param params
     */
    void add(NoticeAddRequest params) throws Exception;

    /**
     * 更新
     * @param params
     */
    void update(NoticeUpdateRequest params) throws Exception;

    /**
     * 已读
     * @param id
     */
    void read(String id);

    /**
     * 查询已读记录
     * @param id
     */
    ReadStatisticsDto queryReadInfo(String id);

    /**
     * 处理已读
     * @param noticeId
     * @return
     */
    NoticeDetailDto getOne(String noticeId);
}
